// Type definitions for non-npm package Node.js 11.13
// Project: http://nodejs.org/
// Definitions by: Microsoft TypeScript <https://github.com/Microsoft>
//                 DefinitelyTyped <https://github.com/DefinitelyTyped>
//                 Alberto Schiabel <https://github.com/jkomyno>
//                 Alexander T. <https://github.com/a-tarasyuk>
//                 Alvis HT Tang <https://github.com/alvis>
//                 Andrew Makarov <https://github.com/r3nya>
//                 Benjamin Toueg <https://github.com/btoueg>
//                 Bruno Scheufler <https://github.com/brunoscheufler>
//                 Chigozirim C. <https://github.com/smac89>
//                 Christian Vaagland Tellnes <https://github.com/tellnes>
//                 David Junger <https://github.com/touffy>
//                 Deividas Bakanas <https://github.com/DeividasBakanas>
//                 Eugene Y. Q. Shen <https://github.com/eyqs>
//                 Flarna <https://github.com/Flarna>
//                 Hannes Magnusson <https://github.com/Hannes-Magnusson-CK>
//                 Hoàng Văn Khải <https://github.com/KSXGitHub>
//                 Huw <https://github.com/hoo29>
//                 Kelvin Jin <https://github.com/kjin>
//                 Klaus Meinhardt <https://github.com/ajafff>
//                 Lishude <https://github.com/islishude>
//                 Mariusz Wiktorczyk <https://github.com/mwiktorczyk>
//                 Matthieu Sieben <https://github.com/matthieusieben>
//                 Mohsen Azimi <https://github.com/mohsen1>
//                 Nicolas Even <https://github.com/n-e>
//                 Nicolas Voigt <https://github.com/octo-sniffle>
//                 Parambir Singh <https://github.com/parambirs>
//                 Sebastian Silbermann <https://github.com/eps1lon>
//                 Simon Schick <https://github.com/SimonSchick>
//                 Thomas den Hollander <https://github.com/ThomasdenH>
//                 Wilco Bakker <https://github.com/WilcoBakker>
//                 wwwy3y3 <https://github.com/wwwy3y3>
//                 Zane Hannan AU <https://github.com/ZaneHannanAU>
//                 Jeremie Rodriguez <https://github.com/jeremiergz>
//                 Samuel Ainsworth <https://github.com/samuela>
//                 Kyle Uehlein <https://github.com/kuehlein>
//                 Jordi Oliveras Rovira <https://github.com/j-oliveras>
//                 Thanik Bhongbhibhat <https://github.com/bhongy>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped

// NOTE: These definitions support NodeJS and TypeScript 3.2.

// NOTE: TypeScript version-specific augmentations can be found in the following paths:
//          - ~/base.d.ts         - Shared definitions common to all TypeScript versions
//          - ~/index.d.ts        - Definitions specific to TypeScript 2.1
//          - ~/ts3.2/index.d.ts  - Definitions specific to TypeScript 3.2

// NOTE: Augmentations for TypeScript 3.2 and later should use individual files for overrides
//       within the respective ~/ts3.2 (or later) folder. However, this is disallowed for versions
//       prior to TypeScript 3.2, so the older definitions will be found here.

// Base definitions for all NodeJS modules that are not specific to any version of TypeScript:
/// <引用 路径="base.d.cts"/>

// TypeScript 2.1-specific augmentations:

// Forward-declarations for needed types from es2015 and later (in case users are using `--lib es5`)
// Empty interfaces are used here which merge fine with the real declarations in the lib XXX files
// just to ensure the names are known and node typings can be sued without importing these libs.
// if someone really needs these types the libs need to be added via --lib or in tsconfig.json

//@@{ 映射构造函数_:MapConstructor }
接口 映射构造函数_ { }

//@@{ 弱映射构造函数_:WeakMapConstructor }
接口 弱映射构造函数_ { }

//@@{ 集合构造函数_:SetConstructor }
接口 集合构造函数_ { }

//@@{ 弱集合构造函数_:WeakSetConstructor }
接口 弱集合构造函数_ { }

//@@{ 集合_:Set }
接口 集合_<T> {}

//@@{ 映射_:Map }
接口 映射_<K, V> {}

//@@{ 只读集合_:ReadonlySet }
接口 只读集合_<T> {}

//@@{ 迭代器结果_:IteratorResult }
接口 迭代器结果_<T> { }

//@@{ 可迭代_:Iterable }
接口 可迭代_<T> { }

//@@{ 迭代器_:Iterator }
接口 迭代器_<T> {

    //@@{ 下个:next, 迭代器结果_:IteratorResult }
    下个(值?: 任意): 迭代器结果_<T>;
}

//@@{ 可迭代迭代器_:IterableIterator }
接口 可迭代迭代器_<T> { }

//@@{ 异步可迭代迭代器_:AsyncIterableIterator }
接口 异步可迭代迭代器_<T> {}

//@@{ 符号构造函数_:SymbolConstructor }
接口 符号构造函数_ {

    //@@{ 迭代器:iterator }
    只读 迭代器: 符号;

    //@@{ 异步迭代器:asyncIterator }
    只读 异步迭代器: 符号;
}

//@@{ 符号_:Symbol, 符号构造函数_:SymbolConstructor }
声明 定义 符号_: 符号构造函数_;
// even this is just a forward declaration some properties are added otherwise
// it would be allowed to pass anything to e.g. Buffer.from()

//@@{ 共享数组缓冲区_:SharedArrayBuffer }
接口 共享数组缓冲区_ {

    //@@{ 字节长度:byteLength }
    只读 字节长度: 数字;

    //@@{ 分切:slice, 共享数组缓冲区_:SharedArrayBuffer }
    分切(开始?: 数字, 结束?: 数字): 共享数组缓冲区_;
}

声明 模块 "util" {

    //@@{ 检查:inspect }
    名域 检查 {

        //@@{ 自定义:custom }
        常量 自定义: 符号;
    }

    //@@{ 转为预设:promisify }
    名域 转为预设 {

        //@@{ 自定义:custom }
        常量 自定义: 符号;
    }

    //@@{ 类型组:types }
    名域 类型组 {

        //@@{ 是大数数组64:isBigInt64Array }
        函数 是大数数组64(值: 任意): 真假;

        //@@{ 是大正整数数组64:isBigUint64Array }
        函数 是大正整数数组64(值: 任意): 真假;
    }
}
